package com.synjones.wschool.face.serviceImpl;

import com.synjones.wschool.face.domain.Student;
import com.synjones.wschool.face.mapper.StudentMapper;
import com.synjones.wschool.face.service.StudentService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.Collections;
import java.util.List;

/**
 * Created by 24398 on 2018/8/3.
 */
@Service
public class StudentServiceImpl implements StudentService {

    @Resource
    private StudentMapper studentMapper;

    @Override
    public List<Student> listByIds(List<Long> studentIds) {
        if(studentIds == null || studentIds.isEmpty()){
            return Collections.emptyList();
        }

        List<Student> students = this.studentMapper.listByStudentIds(studentIds);
        return students;
    }
}
